GtkGLArea: Only re-allocate buffers during paint
authorAlexander Larsson <alexl@redhat.com>
Tue, 16 Dec 2014 12:25:23 +0000 (13:25 +0100)
committerAlexander Larsson <alexl@redhat.com>
Tue, 16 Dec 2014 12:25:23 +0000 (13:25 +0100)
commit08853c7364651390d888b04e159915d9ba77f7ba
tree01a9be27fde4f012ae713079b50534110979565c
parenta1a01983f717a464e89ff2b569a5c61a2e3239c3
GtkGLArea: Only re-allocate buffers during paint

This drops the maybe_allocate_buffers that re-allocates buffers
at any point. Instead we just set have_buffers to FALSE and have
the buffers re-created when needed.

This also makes the buffer creation code imdeponent and makes it
clean up no longer needed buffers in order to handle being called
multiple times due to the above.

We also ensure we re-allocate the buffers when we're resizing
and the buffers are already created.
gtk/gtkglarea.c